package Decorator;

import java.util.ArrayList;

public class ToppingDecorator extends PizzaBase {
 
    public ToppingDecorator(String tName, double tPrice, PizzaBase pb) {
        this.setName(tName);
        this.setPrice(tPrice);
        this.pbs.add(pb);
    }

    public void setName(String tName) {
        this.name = tName;
        //this.names.add(name);
    }

    public String getName() {
        return name;
    }

    public void setPrice(double tPrice) {
        this.price = tPrice;
        //this.totalPrice += this.price;
    }

    public double getPrice() {
        return price;
    }
}
